<div class="am-u-sm-12 widget main-w" >
	{if $notPopup}
	<ol class="am-breadcrumb">
		<li><a href="{:url('/admin/index')}">首页</a></li>
		<li><a href="{:url('index')}">业务管理</a></li>
		<li><a href="{:url('index')}">车辆管理</a></li>
		<li class="am-active">事故管理</li>
	</ol>
	{/if}
	<div class="am-u-sm-12 cl-p">
		<form class="am-form-inline tpl-form-border-form" action="" method="get">
			<div class="am-u-sm-12 cl-p" >
				
				<div class="am-form-group am-u-sm-2">
					<input type="hidden" class="car_type_id" name="car_type_id" value="{$item.car_type_id}" />
					<input type="text" class="am-form-field  car_type" name="car_type" value="{$Think.get.car_type}" placeholder="点击选择车型" readonly="">
				</div>
				<div class="am-form-group am-u-sm-2">
					<input type="text" class="am-form-field" name="number" placeholder="请输入车牌号" value="{$Think.get.number}">
				</div>
				<div class="am-form-group am-u-sm-2">
					<input type="text" class="am-form-field" name="name" placeholder="请输入公司名" value="{$Think.get.name}">
				</div>
				<div class="am-form-group am-u-sm-2">
					<input type="text" class="am-form-field" name="rent_company" placeholder="请输入租赁公司" value="{$Think.get.rent_company}">
				</div>
				<div class="am-u-sm-4">
					<button type="submit" class="am-btn am-btn-sm am-btn-primary am-radius">查询<i class="am-icon-search"></i></button> 
				</div>
			</div>
			
		</form>
	</div>
	<div style="padding: 10px;" class="am-u-sm-12">
		<div class="am-btn-group am-u-sm-12 am-btn-group-xs cl-p">
			<a href="{:url('add')}" class="am-btn am-btn-default"><span class="am-icon-plus"></span> 新增</a>
		</div>
		<table width="100%" class="am-table am-table-compact am-table-bordered am-table-radius am-table-striped am-text-truncate tpl-table-black" id="car">
			<thead>
				<tr>
					
					<th>车牌号</th>
					<th>司机</th>
					<th>订单号</th>
					<th>所属公司</th>
					<th>注册时间</th>
					
					<th>状态</th>
					<th>操作</th>
					
					
					
				</tr>
			</thead>
			<tbody>
				{foreach $list as $key => $item}
				<tr data-id="{$item.car_id}" data-number = "{$item.number}">
					
					
					
					
					<td>
						<a href="{:url('detail',['car_id'=>$item['car_id'] ])}">{$item.number?:'-'}</a>
					</td>
					<!--<td>{if $item.car_brand_id}{$car_brands[$item.car_brand_id]}{$car_models[$item.car_model_id]}{$car_series[$item.car_series_id]}{else/}暂无信息{/if}</td>-->
					<td>{$item.brand_name}</td>
					<td>{$car_types[$item.car_type_id]?:'-'}</td>
					<td>{$item.car_rental_name}</td>
					<td>{$item.register_time}</td>
					{if $Think.get.filter}
					{else/}
					<td class="am-text-{$item.state==9?'danger':'success'}">{$item.state==9?'已禁用':'已启用'}</td>
					{if $op == 'search'||$op == 'unbind'||$op == 'bind'} {else/}
					<td>
						<div class="tpl-table-black-operation">
							 {if $item.state == 9}
							<a href="javascript:;" class="startusing" data-method="startusing">
								<i class="am-icon-pencil"></i> 启用
							</a>
							{else/}
							<a href="javascript:;" class="tpl-table-black-operation-del forbidden" data-method="forbidden">
								<i class="am-icon-trash"></i> 禁用
							</a>
							{/if}
							<a href="{:url('edit',['car_id'=>$item.car_id])}{if $Think.get.page}?page={$Think.get.page}{else/}?page=1{/if}">
								<i class="am-icon-pencil"></i> 编辑
							</a>
							<a href="javascript:;" class="tpl-table-black-operation-del delete-list" data-method="delete">
								<i class="am-icon-trash"></i> 删除
							</a>
							<a class="showTrack" data-method="showmap" data-location="">
								<i class="am-icon-map"></i> 当前位置
							</a>
							

						</div>
					</td>
					{/if}
					{/if}
				</tr>
				{/foreach}
				<!-- more data -->
			</tbody>

		</table>
		<div class="am-u-lg-12 am-cf">
			{if $op == 'search'||$op == 'unbind'||$op == 'bind'} {else/}
			<div class="am-fl">
				<a href="{:url('audit')}" type="submit" class="am-btn am-btn-sm am-btn-primary am-radius">购置车辆</a> 
				<a href="{:url('auction')}" type="submit" class="am-btn am-btn-sm am-btn-primary am-radius">车辆拍卖</a> 
				<a href="{:url('scrap')}" type="submit" class="am-btn am-btn-sm am-btn-primary am-radius">车辆报废</a> 
			</div>
			{/if}
			<div class="am-fr">
				{$pager}
			</div>
		</div>
	</div>

</div>
<script type="text/javascript" src="http://webapi.amap.com/maps?v=1.4.2&key={:config('base.mapkey')}&plugin=AMap.Driving"></script>
<script src="//webapi.amap.com/ui/1.0/main.js?v=1.0.11"></script>